ask apps for COMPOUND_TEXT instead of TEXT correctly interpret the return
authorHidetoshi Tajima <tajima@src.gnome.org>
Wed, 8 Aug 2001 17:58:52 +0000 (17:58 +0000)
committerHidetoshi Tajima <tajima@src.gnome.org>
Wed, 8 Aug 2001 17:58:52 +0000 (17:58 +0000)
* gtk/gtkclipboard.c (request_text_received_func): ask apps for
COMPOUND_TEXT instead of TEXT
* gdk/x11/gdkselection-x11.c (gdk_utf8_to_compound_text): correctly
interpret the return value of g_string_to_compound_text()
(#55152)

ChangeLog
ChangeLog.pre-2-0
ChangeLog.pre-2-10
ChangeLog.pre-2-2
ChangeLog.pre-2-4
ChangeLog.pre-2-6
ChangeLog.pre-2-8
gdk/x11/gdkselection-x11.c
gtk/gtkclipboard.c

index 8081f8a585f73b563318899b04a34d33f4a89e77..6f7cda10ece304fb79f22609a545aa316269c7da 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2001-08-08  HideToshi Tajima  <tajima@eng.sun.com>
+
+       * gtk/gtkclipboard.c (request_text_received_func): ask apps for
+       COMPOUND_TEXT instead of TEXT
+       * gdk/x11/gdkselection-x11.c (gdk_utf8_to_compound_text): correctly
+       interpret the return value of g_string_to_compound_text()
+       (#55152)
+
 2001-08-08  Matthias Clasen  <matthiasc@waldgeist.poet.de>
 
        * gtk/gtktreestore.c (gtk_tree_store_iter_n_children): Don't
index 8081f8a585f73b563318899b04a34d33f4a89e77..6f7cda10ece304fb79f22609a545aa316269c7da 100644 (file)
@@ -1,3 +1,11 @@
+2001-08-08  HideToshi Tajima  <tajima@eng.sun.com>
+
+       * gtk/gtkclipboard.c (request_text_received_func): ask apps for
+       COMPOUND_TEXT instead of TEXT
+       * gdk/x11/gdkselection-x11.c (gdk_utf8_to_compound_text): correctly
+       interpret the return value of g_string_to_compound_text()
+       (#55152)
+
 2001-08-08  Matthias Clasen  <matthiasc@waldgeist.poet.de>
 
        * gtk/gtktreestore.c (gtk_tree_store_iter_n_children): Don't
index 8081f8a585f73b563318899b04a34d33f4a89e77..6f7cda10ece304fb79f22609a545aa316269c7da 100644 (file)
@@ -1,3 +1,11 @@
+2001-08-08  HideToshi Tajima  <tajima@eng.sun.com>
+
+       * gtk/gtkclipboard.c (request_text_received_func): ask apps for
+       COMPOUND_TEXT instead of TEXT
+       * gdk/x11/gdkselection-x11.c (gdk_utf8_to_compound_text): correctly
+       interpret the return value of g_string_to_compound_text()
+       (#55152)
+
 2001-08-08  Matthias Clasen  <matthiasc@waldgeist.poet.de>
 
        * gtk/gtktreestore.c (gtk_tree_store_iter_n_children): Don't
index 8081f8a585f73b563318899b04a34d33f4a89e77..6f7cda10ece304fb79f22609a545aa316269c7da 100644 (file)
@@ -1,3 +1,11 @@
+2001-08-08  HideToshi Tajima  <tajima@eng.sun.com>
+
+       * gtk/gtkclipboard.c (request_text_received_func): ask apps for
+       COMPOUND_TEXT instead of TEXT
+       * gdk/x11/gdkselection-x11.c (gdk_utf8_to_compound_text): correctly
+       interpret the return value of g_string_to_compound_text()
+       (#55152)
+
 2001-08-08  Matthias Clasen  <matthiasc@waldgeist.poet.de>
 
        * gtk/gtktreestore.c (gtk_tree_store_iter_n_children): Don't
index 8081f8a585f73b563318899b04a34d33f4a89e77..6f7cda10ece304fb79f22609a545aa316269c7da 100644 (file)
@@ -1,3 +1,11 @@
+2001-08-08  HideToshi Tajima  <tajima@eng.sun.com>
+
+       * gtk/gtkclipboard.c (request_text_received_func): ask apps for
+       COMPOUND_TEXT instead of TEXT
+       * gdk/x11/gdkselection-x11.c (gdk_utf8_to_compound_text): correctly
+       interpret the return value of g_string_to_compound_text()
+       (#55152)
+
 2001-08-08  Matthias Clasen  <matthiasc@waldgeist.poet.de>
 
        * gtk/gtktreestore.c (gtk_tree_store_iter_n_children): Don't
index 8081f8a585f73b563318899b04a34d33f4a89e77..6f7cda10ece304fb79f22609a545aa316269c7da 100644 (file)
@@ -1,3 +1,11 @@
+2001-08-08  HideToshi Tajima  <tajima@eng.sun.com>
+
+       * gtk/gtkclipboard.c (request_text_received_func): ask apps for
+       COMPOUND_TEXT instead of TEXT
+       * gdk/x11/gdkselection-x11.c (gdk_utf8_to_compound_text): correctly
+       interpret the return value of g_string_to_compound_text()
+       (#55152)
+
 2001-08-08  Matthias Clasen  <matthiasc@waldgeist.poet.de>
 
        * gtk/gtktreestore.c (gtk_tree_store_iter_n_children): Don't
index 8081f8a585f73b563318899b04a34d33f4a89e77..6f7cda10ece304fb79f22609a545aa316269c7da 100644 (file)
@@ -1,3 +1,11 @@
+2001-08-08  HideToshi Tajima  <tajima@eng.sun.com>
+
+       * gtk/gtkclipboard.c (request_text_received_func): ask apps for
+       COMPOUND_TEXT instead of TEXT
+       * gdk/x11/gdkselection-x11.c (gdk_utf8_to_compound_text): correctly
+       interpret the return value of g_string_to_compound_text()
+       (#55152)
+
 2001-08-08  Matthias Clasen  <matthiasc@waldgeist.poet.de>
 
        * gtk/gtktreestore.c (gtk_tree_store_iter_n_children): Don't
index b52bf2f102438109895879ce1816f4a8929c9647..1b1e73553b2d664b796aada64fb3dc9a5c6a3853 100644 (file)
@@ -639,6 +639,7 @@ gdk_utf8_to_compound_text (const gchar *str,
     
   result = gdk_string_to_compound_text (locale_str,
                                        encoding, format, ctext, length);
+  result = (result == Success? TRUE : FALSE);
   
   g_free (locale_str);
 
index c64d4c0b51c011af6a187cede87e2422f1f720e5..9022abb85502912bb824b15b15298e39b61a667a 100644 (file)
@@ -641,18 +641,18 @@ request_text_received_func (GtkClipboard     *clipboard,
 
   if (!result)
     {
-      /* If we asked for UTF8 and didn't get it, try text; if we asked
-       * for text and didn't get it, try string.  If we asked for
-       * anything else and didn't get it, give up.
+      /* If we asked for UTF8 and didn't get it, try compound_text;
+       * if we asked for compound_text and didn't get it, try string;
+       * If we asked for anything else and didn't get it, give up.
        */
       if (selection_data->target == gdk_atom_intern ("UTF8_STRING", FALSE))
        {
          gtk_clipboard_request_contents (clipboard,
-                                         gdk_atom_intern ("TEXT", FALSE), 
+                                         gdk_atom_intern ("COMPOUND_TEXT", FALSE), 
                                          request_text_received_func, info);
          return;
        }
-      else if (selection_data->target == gdk_atom_intern ("TEXT", FALSE))
+      else if (selection_data->target == gdk_atom_intern ("COMPOUND_TEXT", FALSE))
        {
          gtk_clipboard_request_contents (clipboard,
                                          GDK_TARGET_STRING,